home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1999 March / EnigmA AMIGA RUN 35 (1999)(G.R. Edizioni)(IT)[!][issue 1999-03].iso / earcd / utils / benchtrash / extras / park.readme < prev    next >
Text File  |  1999-01-01  |  9KB  |  258 lines

  1. Short:    Parks devices and ejects media
  2. Uploader: thor@math.tu-berlin.de (Thomas Richter)
  3. Author:   thor@math.tu-berlin.de (Thomas Richter)
  4. Type:     disk/misc    
  5. Version:  1.09
  6. Requires: Os 2.04
  7.  
  8. This tool ejects, parks or restarts a HD unit, either given by its DOS 
  9. device name or the name and unit of the exec device driver. All partitions 
  10. on the parked unit will be unaccessible to the dos afterwards. To be able to
  11. restart the HD, "Park" can be made resident.
  12.  
  13. _____________________________________________________________________________
  14.  
  15. Version 1.08:
  16.  
  17. Added more sanity checks to avoid Enforcer hits.
  18. _____________________________________________________________________________
  19.  
  20. Version 1.08:
  21.  
  22. If the NOCHECK option is present, Park no longer rejects to "eject"
  23. empty drives, i.e. to open an empty CD drive or similar. 
  24. Thanks to Nils Goers for testing.
  25.  
  26. _____________________________________________________________________________
  27.  
  28. Version 1.07:
  29.  
  30. Fixed a bug that caused an unnecessary "out of memory" failure in case no
  31. disk to be ejected is present.
  32.  
  33. Park uses now a smarter algorithm to decide whether the given argument is
  34. a dos device or an exec device name.
  35.  
  36. Better check for the SCSI result codes, the error code returned is now
  37. more "AmigaDos like".
  38. _____________________________________________________________________________
  39.  
  40. Version 1.06:
  41.  
  42. Added a workaround for a feature of the gvpscsi.device and the FFS.
  43. _____________________________________________________________________________
  44.  
  45. Version 1.05:
  46.  
  47. Added a workaround for a bug in the AmiCFDS, added the NOCHECK option.
  48. _____________________________________________________________________________
  49.  
  50. Version 1.04:
  51.  
  52. Internal release, unpublished.
  53. _____________________________________________________________________________
  54.  
  55. Version 1.03:
  56.  
  57. Added the EJECT argument - *should* be used with the SCSI argument, too.
  58. Added the EJECTDELAY, STARTDELAY and FLUSHDELAY arguments that define 
  59. command specific delays.
  60. _____________________________________________________________________________
  61.  
  62. Version 1.02:
  63.  
  64. Park checks now if a device is already parked (or, to be precise, if the
  65. filing system is shut down) and fails if the user tries to park it again.
  66. _____________________________________________________________________________
  67.  
  68. Version 1.01:
  69.  
  70. Added an explicit check whether the handler name supplied does really contain
  71. a colon.
  72. _____________________________________________________________________________
  73.  
  74. Synopsis:
  75.  
  76. Park     HANDLER=DEVICE/A,UNIT/N,FLAGS/N,SCSI/S,
  77.     ON=START/S,EJECT/S,EJECTDELAY/K/N,STARTDELAY/K/N,
  78.     FLUSHDELAY/K/N,INHIBITDELAY/K/N,NOCHECK/S
  79.  
  80.  
  81. HANDLER:    DOS Device name to be parked, or name of the volume. To 
  82.         restart a unit, this must be the device name.
  83.         This *must* be the name of the dos device driver, i.e.
  84.         a string like "DH0:" or "SYS:".        
  85.         Alternatively, this may be the name of the exec.device, i.e.
  86.         "oktagon.device" or "gvpscsi.device".
  87.  
  88. UNIT:        The unit number of the exec device. Makes only sense if
  89.         HANDLER is an exec style device name.
  90.  
  91. FLAGS:        The flags for opening the device. Defaults to zero and is
  92.         usually not required.
  93.  
  94. SCSI:        If given, try to park the unit with direct SCSI commands.
  95.         This should work with all scsi.device compatible device
  96.         drivers.
  97.         If not given, try to use the TD_EJECT, CMD_START 
  98.         and CMD_STOP.
  99.  
  100.         Unfortunately, most device drivers do not support 
  101.         TD_EJECT, CMD_START/STOP. The "SCSI" keyword is 
  102.         therefore almost always required.
  103.  
  104. ON=START:    Restart the device and the partitions in question.
  105.  
  106.  
  107. EJECT:        Eject the given device, if possible. In almost all
  108.         cases the SCSI keyword IS required since there is almost
  109.         no device which implements the - documented though -
  110.         command TD_EJECT
  111.  
  112. EJECTDELAY:    The delay in 50th of seconds Park should wait after
  113.         ejecting and before re-running the filing system. Defaults
  114.         to 50, i.e. one second.
  115.  
  116. STARTDELAY:    The delay in 50th of seconds Park has to wait after
  117.         having started a device until the filing system is allowed
  118.         to touch the disk again. Thus, this should be the spin-up
  119.         delay of the device. Defaults to 50, i.e. one second.
  120.  
  121. FLUSHDELAY:    The delay in 50th of seconds Park waits for the filing 
  122.         system to execute ACTION_FLUSH, i.e. to flush its buffers
  123.         to the disk. Unfortunately, this packet is broken - which
  124.         requires this ugly, and unsafe(!) workaround.
  125.  
  126. INHIBITDELAY:    The delay in 50th of a second park waits after stopping
  127.         the filing system and before parking the device. This is
  128.         required by the gvpscsi.device since this device fiddles
  129.         on its own in the device list of the DOS (Bah!) and may
  130.         lead to enforcer hits of the FFS. Defaults to one second. 
  131.  
  132. NOCHECK:    Bypasses the test if the filing system of the drive(s) to
  133.         be parked is up and working. If you see a message like
  134.         "Drive xyz is already stopped", but the handler is just
  135.         disabled for whatever reason, insert this argument.
  136.  
  137. _____________________________________________________________________________
  138.  
  139. Examples:
  140.  
  141. Park all partitions on the oktagon.device, unit 2: 
  142. (The oktagon knowns CMD_STOP, SCSI is not required)
  143.  
  144.     Park oktagon.device unit 2
  145.  
  146.  
  147. Park all partitions on the gvpscsi.device, unit 6:
  148. (The gvpscsi.device does NOT know the CMD_STOP, SCSI is required)
  149.  
  150.     Park gvpscsi.device unit 6 scsi
  151.  
  152. The "device" keyword is very important in both cases.
  153.  
  154.  
  155. Park the partition DH0: and all other partitions on the same device:
  156.  
  157.     Park DH0: scsi
  158.  
  159.  
  160. Restart DH0: and all other partitions on that device:
  161.  
  162.     Park DH0: on scsi
  163.  
  164.  
  165. Eject a ZIP drive, named ZIP:
  166.  
  167.     Park ZIP: scsi eject
  168.  
  169.  
  170. Eject a SCSI CD, named CD0:
  171.  
  172.     Park CD0: scsi eject nocheck flushdelay=0 ejectdelay=0
  173.  
  174. A flush delay isn't needed here because a CD filing system can't write
  175. anything to a CD.
  176.  
  177. _____________________________________________________________________________
  178.  
  179.                          The THOR-Software Licence (v2, 24th June 1998)
  180.  
  181.  
  182. This License applies to the computer programs known as "Park".
  183. The "Program", below, refers to such program. The "Archive" refers to 
  184. the package of distribution, as prepared by the author of the Program, 
  185. Thomas Richter. Each licensee is addressed as "you".
  186.  
  187.  
  188. The Program and the data in the archive are freely distributable
  189. under the restrictions stated below, but are also Copyright (c)
  190. Thomas Richter.
  191.  
  192. Distribution of the Program, the Archive and the data in the Archive by a
  193. commercial organization without written permission from the author to any
  194. third party is prohibited if any payment is made in connection with such
  195. distribution, whether directly (as in payment for a copy of the Program) or
  196. indirectly (as in payment for some service related to the Program, or
  197. payment for some product or service that includes a copy of the Program
  198. "without charge"; these are only examples, and not an exhaustive enumeration
  199. of prohibited activities).
  200.  
  201.  
  202. However, the following methods of distribution
  203. involving payment shall not in and of themselves be a violation of this
  204. restriction:
  205.  
  206.  
  207. (i) Posting the Program on a public access information storage and
  208. retrieval service for which a fee is received for retrieving information
  209. (such as an on-line service), provided that the fee is not
  210. content-dependent (i.e., the fee would be the same for retrieving the same
  211. volume of information consisting of random data).
  212.  
  213.  
  214. (ii) Distributing the Program on a CD-ROM, provided that
  215.  
  216. a) the Archive is reproduced entirely and verbatim on such CD-ROM, including
  217. especially this licence agreement;
  218.  
  219. b) the CD-ROM is made available to the public for a nominal fee only,
  220.  
  221. c) a copy of the CD is made available to the author for free except for
  222. shipment costs, and
  223.  
  224. d) provided further that all information on such CD-ROM is redistributable
  225. for non-commercial purposes without charge.
  226.  
  227.  
  228. Redistribution of a modified version of the Archive, the Program or the
  229. contents of the Archive is prohibited in any way, by any organization,
  230. regardless whether commercial or non-commercial. Everything must be kept
  231. together, in original and unmodified form.
  232.  
  233.  
  234.  
  235.  
  236. Limitations.
  237.  
  238.  
  239. THE PROGRAM IS PROVIDED TO YOU "AS IS", WITHOUT WARRANTY. THERE IS NO
  240. WARRANTY FOR THE PROGRAM, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT
  241. LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
  242. PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. THE ENTIRE
  243. RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD
  244. THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY
  245. SERVICING, REPAIR OR CORRECTION.
  246.  
  247.  
  248. IF YOU DO NOT ACCEPT THIS LICENCE, YOU MUST DELETE THE PROGRAM, THE ARCHIVE
  249. AND ALL DATA OF THIS ARCHIVE FROM YOUR STORAGE SYSTEM. YOU ACCEPT THIS
  250. LICENCE BY USING OR REDISTRIBUTING THE PROGRAM.
  251.  
  252.  
  253.                                                         Thomas Richter
  254. ____________________________________________________________________________
  255.  
  256. Thomas,        
  257.     March 1999
  258.